<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
    <meta name="author" content="order by dede58.com"/>
	<title>租车管理登录</title>
	<meta name="renderer" content="webkit">	
	<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">	
	<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
	<meta name="apple-mobile-web-app-status-bar-style" content="black">	
	<meta name="apple-mobile-web-app-capable" content="yes">	
	<meta name="format-detection" content="telephone=no">	
	<!-- load css -->
	<link rel="stylesheet" type="text/css" href="login/common/layui/css/layui.css" media="all">
	<link rel="stylesheet" type="text/css" href="login/css/login.css" media="all">
</head>
<body>
 <div class="layui-canvs"></div> 
<div class="layui-layout layui-layout-login">
	<h1>
		 <strong>租车管理系统</strong>
		 <em>Management System</em>
	</h1>
	<div class="layui-user-icon larry-login">
		 <input type="text" placeholder="账号" id="username" class="login_txtbx"/>
	</div>
	<div class="layui-pwd-icon larry-login">
		 <input type="password" id="password" placeholder="密码" class="login_txtbx"/>
	</div>
     <div class="larry-login">
    	<div class="layui-code-box">
    		<input type="text" id="code" name="code" placeholder="验证码" maxlength="4" class="login_txtbx">
            <img src="/login/verificationCode" alt="" class="verifyImg" id="verifyImg"/>
    	</div>
    </div> 
    <div class="layui-submit larry-login">
    	<input type="button" value="立即登陆" class="submit_btn"/>
    </div>
    <div class="layui-login-text">
    	<p>© 2017-2018 O98K 版权所有</p>
        <p>鄂xxxxxx</p>
    </div>
</div>

<script type="text/javascript" src="login/common/layui/lay/dest/layui.all.js"></script>
<script type="text/javascript" src="login/js/login.js"></script>
<script type="text/javascript" src="login/jsplug/jparticle.jquery.js"></script>
<!--<script type="text/javascript" src="js/jquery-3.3.1.min.js"></script>-->
<script type="text/javascript" src="js/commonUtils.js"></script>
<script type="text/javascript">
$(function(){
    $("#verifyImg").click(function () {
        $("#verifyImg").html("");
        /*var src = "zcyzm?t=new&ik=l_image_code&ss=" + Math.random() + "&l_key=" + logonkey;*/
        var src = "/login/verificationCode?t=new&ik=l_image_code&ss=" + Math.random();
        $("#verifyImg").attr("src", src);
    })
    /*function pushdown() {
        $("#verifyImg").html("");
        /!*var src = "zcyzm?t=new&ik=l_image_code&ss=" + Math.random() + "&l_key=" + logonkey;*!/
        var src = "/login/verificationCode?t=new&ik=l_image_code&ss=" + Math.random();
        $("#verifyImg").attr("src", src);
    }*/
	$(".layui-canvs").jParticle({
		background: "#141414",
		color: "#E6E6E6"
	});
	//登录链接测试，使用时可删除
	$(".submit_btn").click(function(){
        serviceSyncRequest("/login/validateImageCodes",{randomStr:$("#code").val()},function (responseData) {
				if(responseData.Status=='0'){
				    var param = {
                        username:$("#username").val(),
						password:$("#password").val()
					}
                    serviceSyncRequest("/login/login.do",param,function (data) {
						if(data.Status=='0000'){
						    window.location.href='/indexpage/index.html';
						}
					})
				}else {
				    alert("验证码错误")
				}
        });

	  // location.href="index.html";

	});
});
</script>
</body>
</html>